package com.ytjj.common.enums;

import lombok.Getter;

/**
 * @Description 支付类型
 *
 * @Version 1.0
 *
 */
@Getter
public enum PaySourceEnum {
    WX("WX","微信"),
    APP("APP","微信"),
    JSAPI("JSAPI","微信"),
    MWEB("MWEB","微信"),
    MWEB2("MWEB2","微信"),
    ISV_MWEB("ISV-MWEB","微信"),
    ISV_APP("ISV-APP","微信"),
    ISV_JSAPI("ISV-JSAPI","微信"),
    ALIPAY("ALIPAY","支付宝"),
    ALIPAY_JSAPI("ALIPAY-JSAPI","支付宝小程序"),
    ADAPAY("H5-ADAPAY-MINI","汇付天下-小程序"),
    ADAPAY_OLD("ADAPAY","汇付天下-小程序"),

    UPAY("UPAY","首信易"),

    ZSY("ZSY","智收营"),

    HFTX("HFTX","汇付天下");




    String type;
    String name;

    PaySourceEnum(String type,String name){
        this.type = type;
        this.name = name;
    }

    public static String getPayType(String type) {
        for (PaySourceEnum payTypeEnums : PaySourceEnum.values()) {
            if (payTypeEnums.type.equals(type.toUpperCase())) {
                return payTypeEnums.getName();
            }
        }
        return "未知";
    }

}
